package service.paidWith;

import relations.Associate;
import relations.belongsTo;
import relations.handle;
import relations.PaidWith;
import dao.AlbumDAO;
import dao.AssociateDAO;
import dao.HandleDAO;
import dao.PaidWithDAO;
import dao.RecordDuplicateException;
import dao.belongsToDAO;
import entities.Customer;
import entities.User;
import entities.Album;
import entities.Order;



public class PaidWithServiceInMemory implements PaidWithService {

	public PaidWithServiceInMemory(){
		
	}
	
	public static PaidWithService newInstance(){
		return new PaidWithServiceInMemory();
	}
	
	/**
	 * Finds a Album based on the Album id.
	 * @param userid - user id
	 * @return the instance of the Album
	 */
	public PaidWith findPaidWith(String creditCardNum, String orderID){
		PaidWithDAO db =  PaidWithDAO.getInstance();
		PaidWith result = null;
		result = db.findPaidWith(creditCardNum, orderID);
		return result;
	}
	
	
	/**
	 * Adds a new Album to the system.
	 * @param obj - the Album instance to add
	 */
	
	public void addPaidWith(PaidWith obj) throws RecordDuplicateException{
		PaidWithDAO db = PaidWithDAO.getInstance();	
		db.addPaidWith(obj);
		return;
	}











}
